//1.登录请求
import { request } from "../utils";

//1.登录请求
export interface LoginForm {
  mobile: string; // 对应表单的 name="mobile"
  code: string; // 对应表单的 name="code"
}

export function loginAPI(formData: LoginForm) {
  return request({
    url: "/authorizations",
    method: "post",
    data: formData,
  });
}

//2.获取用户个人信息
export function getProfileAPI() {
  return request({
    url: "/user/profile",
    method: "get",
  });
}
